# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=fluxbox
pkgver=1.3.7
pkgrel=6
pkgdesc="A lightweight and highly-configurable window manager"
url="http://www.fluxbox.org"
arch="all"
options="!check"  # Test suite fails to build with Xft link error.
license="MIT"
subpackages="$pkgname-doc"
makedepends="libxinerama-dev libxpm-dev libxrandr imlib2-dev libxrender-dev
	libxrandr-dev freetype-dev libxft-dev xorgproto"
source="https://downloads.sourceforge.net/sourceforge/fluxbox/fluxbox-$pkgver.tar.bz2
	gcc11.patch
	"

prepare() {
	default_prepare

	update_config_sub
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--enable-imlib2 \
		--disable-nls
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
c40cc765f5d542210e18dca21b98b97a048c6685b605a68e2c64f4e886329f4e6d3a3a7e76b3ca0ce488242f38d0ee2a4d6dfebc9ce97d37c68f84c3948aac8c  fluxbox-1.3.7.tar.bz2
86f7c3c0fcafef2f07e1cdb9b7ffa11756a3d6020bc5806d2e2f89575e8c61ec1ffbe7dcc4bea6cfe559f7e557ed9606c13504ea71f56475d11f675346001f71  gcc11.patch
"
